package tt.com.financialmanagement.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import tt.com.common.model.Order;
import tt.com.common.model.OrderProject;
import tt.com.financialmanagement.service.YxCommonPurchaseServe;

@RestController
@RequestMapping(value = "Procurement/business")
//采购单的前端-后端/api/Procurement/business/xxxx


public class YxCommonPurchaseController {

    @Autowired
    private YxCommonPurchaseServe yxCommonPurchaseServe;
    @PostMapping(value = "select/purchase")
    //根据项目id查询采购单信息
    public ResponseEntity selectPurchase(@RequestBody OrderProject orderProject){
        return yxCommonPurchaseServe.selectByOrderId(orderProject);

    }


}
